package com.amkai.aes.webservice.binary.objecthandler.diee;

import java.io.Serializable;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

import com.amkai.aes.aescommon.service.diee.ReportManagerJob;
import com.amkai.aes.aescommon.service.diee.ReportManagerResult;
import com.amkai.aes.server.diee.ReportManagerProvider;
import com.amkai.aes.webservice.binary.JobObjectHandler;

public class ReportManagerHandler implements JobObjectHandler<ReportManagerJob, Serializable, ReportManagerResult> {
	private static final Log logger = LogFactory.getLog(ReportManagerHandler.class);
			
	@Override
	public ReportManagerResult process(ReportManagerJob job, Serializable object) throws Exception {
		ReportManagerProvider mp = new ReportManagerProvider();
		try {
			return mp.processJob(job, object);
		} catch (Throwable e) {
			logger.error("ReportManagerHandler: ", e);
			throw new Exception(e);
		}
	}

}
